package fr.aprr.odyssee.server.domain.entities;

// default package
// Generated Apr 23, 2014 11:01:50 PM by Hibernate Tools 4.0.0

import java.io.Serializable;
import java.util.HashSet;
import java.util.Set;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Table;

/**
 * Onglets generated by hbm2java
 */
@Entity
@Table(name = "ody$conf_onglets", schema = "public")
public class Onglets implements java.io.Serializable {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	private String nomOnglet;
	private District district;
	private int indiceAff;
	private String repertSauve;
	private Integer niveauZoom;
	private Integer rafraich;
	private Serializable def2d;
	private Set<ArchiOnglets> archiOngletses = new HashSet<ArchiOnglets>(0);

	public Onglets() {
	}

	public Onglets(String nomOnglet, int indiceAff) {
		this.nomOnglet = nomOnglet;
		this.indiceAff = indiceAff;
	}

	public Onglets(String nomOnglet, District district, int indiceAff,
			String repertSauve, Integer niveauZoom, Integer rafraich,
			Serializable def2d, Set<ArchiOnglets> archiOngletses) {
		this.nomOnglet = nomOnglet;
		this.district = district;
		this.indiceAff = indiceAff;
		this.repertSauve = repertSauve;
		this.niveauZoom = niveauZoom;
		this.rafraich = rafraich;
		this.def2d = def2d;
		this.archiOngletses = archiOngletses;
	}

	@Id
	@Column(name = "nom_onglet", unique = true, nullable = false, length = 30)
	public String getNomOnglet() {
		return this.nomOnglet;
	}

	public void setNomOnglet(String nomOnglet) {
		this.nomOnglet = nomOnglet;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "nom_district")
	public District getDistrict() {
		return this.district;
	}

	public void setDistrict(District district) {
		this.district = district;
	}

	@Column(name = "indice_aff", nullable = false)
	public int getIndiceAff() {
		return this.indiceAff;
	}

	public void setIndiceAff(int indiceAff) {
		this.indiceAff = indiceAff;
	}

	@Column(name = "repert_sauve", length = 50)
	public String getRepertSauve() {
		return this.repertSauve;
	}

	public void setRepertSauve(String repertSauve) {
		this.repertSauve = repertSauve;
	}

	@Column(name = "niveau_zoom")
	public Integer getNiveauZoom() {
		return this.niveauZoom;
	}

	public void setNiveauZoom(Integer niveauZoom) {
		this.niveauZoom = niveauZoom;
	}

	@Column(name = "rafraich")
	public Integer getRafraich() {
		return this.rafraich;
	}

	public void setRafraich(Integer rafraich) {
		this.rafraich = rafraich;
	}

	@Column(name = "def_2d")
	public Serializable getDef2d() {
		return this.def2d;
	}

	public void setDef2d(Serializable def2d) {
		this.def2d = def2d;
	}

	@OneToMany(fetch = FetchType.LAZY, mappedBy = "onglets")
	public Set<ArchiOnglets> getArchiOngletses() {
		return this.archiOngletses;
	}

	public void setArchiOngletses(Set<ArchiOnglets> archiOngletses) {
		this.archiOngletses = archiOngletses;
	}

}
